Conversation
for more information, see https://pre-commit.ci
for more information, see https://pre-commit.ci
for more information, see https://pre-commit.ci
for more information, see https://pre-commit.ci
for more information, see https://pre-commit.ci
for more information, see https://pre-commit.ci
for more information, see https://pre-commit.ci
for more information, see https://pre-commit.ci
for more information, see https://pre-commit.ci
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR introduces a SQL-based caching core for Cachier, enabling use of SQLAlchemy backends alongside existing pickle, memory, and MongoDB options. Key changes include
- Implementation of a new
_SQLCoreclass insrc/cachier/cores/sql.py, with full CRUD and concurrency handling - Comprehensive test suite in
tests/test_sql_core.pyplus CI and requirements updates to run SQL-backed tests - Updates to
cachierdecorator, documentation inREADME.rst, and CI configurations to integrate the SQL backend
Reviewed Changes
Copilot reviewed 13 out of 13 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| tests/test_sql_core.py | Add end-to-end and edge-case tests for SQL core |
| src/cachier/cores/sql.py | Implement the _SQLCore class using SQLAlchemy |
| src/cachier/core.py | Wire in backend="sql" and sql_engine parameter |
| tests/sql_requirements.txt | Add SQLAlchemy and psycopg2 dependencies |
| README.rst | Document SQL core usage, schema, and limitations |
| .github/workflows/ci-test.yml | Extend CI matrix to run sql-marked tests |
| pyproject.toml | Register sql pytest marker and lint exceptions |
Comments suppressed due to low confidence (1)
tests/test_sql_core.py:64
- Consider adding a test for the
next_time=Truecase to verify that stale entries are returned immediately when thenext_timeflag is enabled.
next_time=False,
Member
Author
|
Ok, this is ready for a review. |
Borda
reviewed
Jul 3, 2025
Borda
approved these changes
Jul 3, 2025
for more information, see https://pre-commit.ci
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.